<template>
  <div class="stepBox" :style="{ width: 156 * stepList.length + 'px' }">
    <div class="step-item" v-for="(item, index) in stepList" :key="index" :class="index == current ? 'active' : ''">{{ index + 1 }}.{{ item }}</div>
  </div>
</template>

<script>
export default {
  name: '',
  props: {
    stepList: {
      type: Array,
    },
    current: {
      type: Number,
      default: 0,
    },
  },
  data() {
    return {};
  },

  methods: {},
};
</script>

<style lang="scss" scoped>
.stepBox {
  background: #e6edff;
  border-radius: 16px;
  color: #262626;
  display: flex;
  align-items: center;
  text-align: center;
  font-weight: bold;
  .step-item {
    width: 156px;
    height: 32px;
    line-height: 32px;
    font-size: 14px;
    &.active {
      background: #5075ff;
      color: #fff;
      border-radius: 16px;
    }
  }
}
</style>